<%-- 公共文件引入jsp --%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@include file="taglibs.jsp" %>
<script type="text/javascript" src="${path}/static/js/lib/jquery-1.11.3.min.js"></script>
<script type="text/javascript">
    //工程跟路径
    var CONTEXT_PATH = '${path}';
    $(function () {
        $.ajaxSetup({
            cache: false, //关闭AJAX缓存
            complete: function (xhr, status) {
                var sessionstatus = xhr.getResponseHeader("sessionstatus"); //通过XMLHttpRequest取得响应头，sessionstatus
                if (sessionstatus == "timeout") { //如果超时就处理 ，指定要跳转的页面
                    alert("您的登录已过期，请重新登录！");
                    window.top.location.replace("${path}");
                }
            }
        });
    });
</script>